(global.webpackJsonp = global.webpackJsonp || []).push([ [ "xg_o2o/confirm/confirm" ], {
    "67a0": function(e, t, i) {
        "use strict";
        (function(e) {
            Object.defineProperty(t, "__esModule", {
                value: !0
            }), t.default = void 0;
            var o = i("9e42"), s = i("b00d"), a = {
                data: function() {
                    return {
                        bgColor: "",
                        textColor: "",
                        graceFullLoading: !0,
                        attach: "",
                        itemid: 0,
                        skuid: 0,
                        issku: 0,
                        skudata: {},
                        itemHead: "",
                        itemTitle: "",
                        marketprice: 0,
                        payprice: 0,
                        orderAddrId: 0,
                        orderId: 0,
                        addressDetail: {},
                        orderDate: "",
                        orderTime: "",
                        couponid: 0,
                        coupon: {},
                        couponTxt: "没有选择优惠券",
                        orderRemarks: "",
                        confirmRemarks: "",
                        isWxPay: !1,
                        userWxInfo: {},
                        tmplIds: [],
                        paybtn: "微信支付",
                        textareaVal: "",
                        selectedimgs: [],
                        subtxt: "发布",
                        uploadServerUrl: "",
                        uploadImg: "",
                        uploadImgs: "",
                        showLogin: !1,
                        addGoodsBtn: "选择配件",
                        addGoods: "配件",
                        goodsList: [],
                        showGoods: !1,
                        goodsTopHeight: 200,
                        goodsTopPadding: 44,
                        totalprice: 0,
                        goodsListHeight: 300,
                        allprice: 0,
                        goodsSelectList: "",
                        servremarks: "请输入您的服务要求(50字内)",
                        teckname: "",
                        tecknameBtn: "",
                        showTeck: 2,
                        addressLngLat: "",
                        perid: 0,
                        pername: "",
                        showPic: !1,
                        goodsimg: "",
                        cussets: [],
                        iskefu: 2,
                        vipStatus: 1,
                        vipDiscount: 10,
                        cityStatus: 0,
                        currentCity: 0,
                        getCity: 0,
                        currentCityName: "",
                        ispre: 0,
                        selectPer: 1,
                        issoon: 2,
                        iscoupon: 1,
                        soonVal: 1,
                        soon: [ {
                            name: "尽快上门",
                            value: "1",
                            checked: !0
                        }, {
                            name: "选择时间",
                            value: "2",
                            checked: !1
                        } ],
                        showBack: !1,
                        cityType: 0,
                        cityCode: 0,
                        cityName: "",
                        cardOrder: {},
                        cardName: "次卡",
                        cardNum: 0,
                        cardOrderId: 0,
                        agreeContent: "",
                        ischeck: !1,
                        show1: !1,
                        toTime: "",
                        showtime: "",
                        selectNum: 1,
                        appid: "",
                        citys: {},
                        citynum: 0,
                        showCitys: []
                    };
                },
                onLoad: function(t) {
                    var i = this;
                    this.appid = s.d, this.selectNum = t.selectnum;
                    var o = getCurrentPages();
                    this.showBack = o.length > 1;
                    var a = e.getStorageSync("agreecheck");
                    this.ischeck = 1 == a, t.perid > 0 && (this.perid = t.perid, this.pername = t.pername);
                    var r = this.$systemInfo.info();
                    if (this.goodsTopHeight = r.windowHeight - r.statusBarHeight - 44 - e.upx2px(100) - r.iPhoneXBottomHeightPx, 
                    this.goodsListHeight = this.goodsTopHeight - 30, this.uploadServerUrl = this.$xRequest.url("entry/wxapp/v4uploadimg"), 
                    t.card > 0) {
                        this.cardOrderId = t.card;
                        var n = this.$xSign.sign("u9order");
                        this.$xRequest.request({
                            url: "entry/wxapp/u9order",
                            data: {
                                xgsign: n,
                                op: "confirmcard",
                                cardorderid: this.cardOrderId
                            },
                            success: function(e) {
                                i.graceFullLoading = !1;
                                var t = JSON.parse(i.$Decrypt(e.data.data));
                                i.paybtn = "提交订单", i.itemid = t.itemid, i.cityCode = t.cityCode, i.cityType = t.cityType, 
                                i.cityName = t.cityName, i.cardOrder = t.cardorder, i.cardName = t.cardname, i.iskefu = t.iskefu, 
                                i.bgColor = t.bgColor, i.textColor = t.textColor, i.toTime = t.totime, i.soon = [ {
                                    name: "尽快" + t.totime,
                                    value: "1",
                                    checked: !0
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !1
                                } ], "wxfb5952a0ea6f5f06" == i.appid && (i.soon = [ {
                                    name: "与客服联系确定上门时间",
                                    value: "1",
                                    checked: !0
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !1
                                } ]), i.attach = t.attach, i.itemHead = i.attach + t.img, i.marketprice = t.marketprice, 
                                i.payprice = t.marketprice, i.allprice = i.floatAdd(Number(i.payprice), Number(i.totalprice)), 
                                i.issku = t.issku, i.cussets = t.cussets, i.skudata = t.skudata, i.issoon = t.issoon, 
                                i.iscoupon = t.iscoupon, i.itemTitle = t.title, i.servremarks = t.servremarks, i.orderAddrId = t.orderAddrId, 
                                i.addressDetail = t.addressDetail, i.addressLngLat = t.lnglat, i.ispre = t.ispre, 
                                i.citys = t.citys, i.showCitys = t.showcity, i.citynum = t.citynum, t.lnglat && i.getCityCode(t.lnglat), 
                                i.tmplIds = t.tmplIds, i.teckname = t.teckname, i.showTeck = t.showteck, i.tecknameBtn = "选择" + t.teckname, 
                                i.vipStatus = t.vipstatus, i.vipDiscount = t.vipdiscount, t.goodsList && (i.goodsList = t.goodsList), 
                                i.addGoods = t.goodssettitle, i.addGoodsBtn = "可选" + t.goodssettitle, t.nickname || (i.showLogin = !0), 
                                i.cityStatus = t.cityStatus, i.currentCity = t.currentCity, i.currentCityName = t.cityname, 
                                i.confirmRemarks = t.remarks, i.showtime = t.showtime, i.perid > 0 && (i.tecknameBtn = "已选" + i.teckname + i.pername), 
                                i.selectPer = t.selectper, i.agreeContent = t.agree;
                            },
                            fail: function(t) {
                                e.hideLoading(), e.showToast({
                                    title: t.data.message,
                                    icon: "none"
                                }), setTimeout(function() {
                                    e.navigateBack({
                                        delta: 1
                                    });
                                }, 1200);
                            },
                            complete: function(e) {}
                        });
                    } else this.itemid = t.itemid, this.orderId = t.oid, this.skuid = t.skuid, this.orderId > 0 ? (n = this.$xSign.sign("v4order_detail"), 
                    this.$xRequest.request({
                        url: "entry/wxapp/v4order_detail",
                        data: {
                            oid: this.orderId,
                            op: "topay",
                            xgsign: n
                        },
                        success: function(t) {
                            i.graceFullLoading = !1;
                            var o = JSON.parse(i.$Decrypt(t.data.data));
                            if (0 == t.data.errno && 1 == o.info) {
                                if (i.vipStatus = o.vipstatus, i.vipDiscount = o.vipdiscount, i.iskefu = o.iskefu, 
                                i.attach = o.attach, i.bgColor = o.bgColor, i.textColor = o.textColor, i.toTime = o.totime, 
                                i.soon = [ {
                                    name: "尽快" + o.totime,
                                    value: "1",
                                    checked: !0
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !1
                                } ], "wxfb5952a0ea6f5f06" == i.appid && (i.soon = [ {
                                    name: "与客服联系确定上门时间",
                                    value: "1",
                                    checked: !0
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !1
                                } ]), i.itemHead = i.attach + o.img, i.selectNum = o.selectnum, i.marketprice = o.marketprice, 
                                i.payprice = o.marketprice, i.cussets = o.cusset, o.goodsList && (i.goodsList = o.goodsList), 
                                i.servremarks = o.servremarks, i.ispre = o.ispre, i.totalprice = o.totalprice, i.allprice = i.floatAdd(Number(i.payprice), Number(i.totalprice)), 
                                i.addGoods = o.goodssettitle, i.addGoodsBtn = "可选" + o.goodssettitle, i.issku = o.issku, 
                                i.issoon = o.issoon, i.iscoupon = o.iscoupon, i.soonVal = o.soonVal, 2 == o.soonVal ? (i.soon = [ {
                                    name: "尽快" + o.totime,
                                    value: "1",
                                    checked: !1
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !0
                                } ], "wxfb5952a0ea6f5f06" == i.appid && (i.soon = [ {
                                    name: "与客服联系确定上门时间",
                                    value: "1",
                                    checked: !1
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !0
                                } ])) : (i.soon = [ {
                                    name: "尽快" + o.totime,
                                    value: "1",
                                    checked: !0
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !1
                                } ], "wxfb5952a0ea6f5f06" == i.appid && (i.soon = [ {
                                    name: "与客服联系确定上门时间",
                                    value: "1",
                                    checked: !0
                                }, {
                                    name: "选择时间",
                                    value: "2",
                                    checked: !1
                                } ])), i.skudata = o.skudata, i.itemTitle = o.title, i.orderAddrId = o.orderAddrId, 
                                i.addressDetail = o.addressDetail, i.cityStatus = o.cityStatus, i.currentCity = o.currentCity, 
                                i.currentCityName = o.cityname, i.cityCode = o.cityCode, i.cityType = o.cityType, 
                                i.cityName = o.cityName, i.addressLngLat = o.latlng, i.citys = o.citys, i.showCitys = o.showcity, 
                                i.citynum = o.citynum, o.latlng && i.getCityCode(o.latlng), i.uploadImg = o.uploadimg ? o.uploadimg : "", 
                                o.uploadimg && setTimeout(function() {
                                    i.$refs.selectimgandupload.setItems([ o.uploadimg ]);
                                }, 300), i.uploadImgs = o.uploadimgs ? o.uploadimgs : "", o.uploadimgs) {
                                    var s = o.uploadimgs.split(",");
                                    setTimeout(function() {
                                        i.$refs.selectimgandupload.setItems(s);
                                    }, 300);
                                }
                                i.orderTime = o.orderDate, i.orderRemarks = o.orderRemarks, i.confirmRemarks = o.remarks, 
                                i.showtime = o.showtime, i.itemid = o.itemid, i.tmplIds = o.tmplIds, i.teckname = o.teckname, 
                                i.showTeck = o.showteck, i.tecknameBtn = o.tecknameBtn, i.selectPer = o.selectper, 
                                1 == o.showteck && (i.perid = o.perid), o.nickname || (i.showLogin = !0), i.agreeContent = o.agree;
                            } else e.showToast({
                                title: t.data.message,
                                icon: "none",
                                duration: 800
                            });
                        }
                    })) : (n = this.$xSign.sign("v4item"), this.$xRequest.request({
                        url: "entry/wxapp/v4item",
                        data: {
                            proid: this.itemid,
                            itemdata: "simple",
                            skuid: this.skuid,
                            xgsign: n,
                            selectnum: this.selectNum,
                            iszero: 1
                        },
                        success: function(e) {
                            i.graceFullLoading = !1;
                            var t = JSON.parse(i.$Decrypt(e.data.data));
                            0 == e.data.errno && (i.cityCode = t.cityCode, i.cityType = t.cityType, i.cityName = t.cityName, 
                            i.iskefu = t.iskefu, i.bgColor = t.bgColor, i.textColor = t.textColor, i.attach = t.attach, 
                            i.itemHead = i.attach + t.img, i.toTime = t.totime, i.soon = [ {
                                name: "尽快" + t.totime,
                                value: "1",
                                checked: !0
                            }, {
                                name: "选择时间",
                                value: "2",
                                checked: !1
                            } ], "wxfb5952a0ea6f5f06" == i.appid && (i.soon = [ {
                                name: "与客服联系确定上门时间",
                                value: "1",
                                checked: !0
                            }, {
                                name: "选择时间",
                                value: "2",
                                checked: !1
                            } ]), i.marketprice = t.marketprice, i.payprice = 1 == t.issku ? t.skudata.price : t.marketprice, 
                            i.allprice = i.floatAdd(Number(i.payprice), Number(i.totalprice)), i.issku = t.issku, 
                            i.cussets = t.cussets, i.skudata = t.skudata, i.issoon = t.issoon, i.iscoupon = t.iscoupon, 
                            i.itemTitle = t.title, i.servremarks = t.servremarks, i.orderAddrId = t.orderAddrId, 
                            i.addressDetail = t.addressDetail, i.addressLngLat = t.lnglat, i.ispre = t.ispre, 
                            i.citys = t.citys, i.showCitys = t.showcity, i.citynum = t.citynum, t.lnglat && i.getCityCode(t.lnglat), 
                            i.tmplIds = t.tmplIds, i.teckname = t.teckname, i.showTeck = t.showteck, i.tecknameBtn = "选择" + t.teckname, 
                            i.vipStatus = t.vipstatus, i.vipDiscount = t.vipdiscount, t.goodsList && (i.goodsList = t.goodsList), 
                            i.addGoods = t.goodssettitle, i.addGoodsBtn = "可选" + t.goodssettitle, t.nickname || (i.showLogin = !0), 
                            i.cityStatus = t.cityStatus, i.currentCity = t.currentCity, i.currentCityName = t.cityname, 
                            i.confirmRemarks = t.remarks, i.showtime = t.showtime, i.perid > 0 && (i.tecknameBtn = "已选" + i.teckname + i.pername), 
                            i.selectPer = t.selectper, i.agreeContent = t.agree);
                        }
                    }));
                },
                onShow: function() {
                    var t = this;
                    e.$once("selectAddr", function(e) {
                        if (t.addressDetail = e.addressDetail, t.orderAddrId = e.addrid, t.addressLngLat = e.addressDetail.city, 
                        "" == e.addressDetail.city) {
                            var i = t.$xSign.sign("v4address");
                            t.$xRequest.request({
                                url: "entry/wxapp/v4address",
                                data: {
                                    op: "city",
                                    addrid: e.addressDetail.id,
                                    province: e.addressDetail.province,
                                    xgsign: i
                                },
                                success: function(e) {
                                    var i = JSON.parse(t.$Decrypt(e.data.data));
                                    0 == e.data.errno && (t.addressLngLat = i, t.getCityCode(i));
                                }
                            });
                        } else t.getCityCode(e.addressDetail.city);
                    }), e.$once("selectDateTime", function(e) {
                        t.orderDate = e.orderDate, t.orderTime = e.orderTime;
                    }), e.$once("selectTeck", function(e) {
                        t.perid = e.perid, 0 == e.perid ? t.tecknameBtn = "系统派单" : t.tecknameBtn = "已选" + t.teckname + e.pername;
                    }), e.$once("selectCoupon", function(i) {
                        if (i.coupon > 0) {
                            e.showLoading({
                                title: "加载中",
                                mask: !0
                            });
                            var o = t.$xSign.sign("v4coupon");
                            t.$xRequest.request({
                                url: "entry/wxapp/v4coupon",
                                data: {
                                    couponid: i.coupon,
                                    xgsign: o,
                                    op: "mycoupon"
                                },
                                success: function(o) {
                                    var s = 1 == t.issku ? t.skudata.price : t.marketprice, a = JSON.parse(t.$Decrypt(o.data.data));
                                    if (0 == o.data.errno && 0 == a.info) {
                                        var r = a.coupon;
                                        if (1 == r.type) if (s - r.filled >= 0) {
                                            t.couponid = i.coupon;
                                            var n = s - r.number;
                                            t.payprice = n.toFixed(2), t.couponTxt = r.txt;
                                        } else t.couponTxt = "此优惠券不可用", t.payprice = s, t.couponid = 0; else if (2 == r.type) {
                                            t.couponid = i.coupon;
                                            var c = s - r.number;
                                            t.payprice = c.toFixed(2), t.couponTxt = r.txt;
                                        } else {
                                            t.couponid = i.coupon;
                                            var d = s * r.number / 100;
                                            t.payprice = d.toFixed(2), t.couponTxt = r.txt;
                                        }
                                        t.allprice = t.floatAdd(Number(t.payprice), Number(t.totalprice));
                                    }
                                    setTimeout(function() {
                                        e.hideLoading();
                                    }, 1e3);
                                }
                            });
                        }
                    });
                },
                methods: {
                    showDialog1: function() {
                        this.show1 = !0;
                    },
                    closeDialog1: function() {
                        this.show1 = !1;
                    },
                    checkedChange: function(t) {
                        this.ischeck = t[0], e.setStorageSync("agreecheck", t[0]);
                    },
                    changeNum: function(t) {
                        t[0] > this.cardOrder.unusenum ? e.showToast({
                            title: "数量不足",
                            icon: "none"
                        }) : this.cardNum = t[0];
                    },
                    soonChange: function(e) {
                        this.soonVal = e;
                    },
                    closeCitys: function() {
                        this.$refs.showCitys.hide();
                    },
                    getCityCode: function(t) {
                        var i = this;
                        if (0 != this.cityType) {
                            var s = t.split(","), a = s[1] + "," + s[0];
                            new o.AMapWX({
                                key: this.$m
                            }).getRegeo({
                                location: a,
                                success: function(t) {
                                    var o = t[0].regeocodeData.addressComponent.adcode;
                                    if (i.citys.hasOwnProperty(o)) ; else if (!i.citys.hasOwnProperty(o)) {
                                        var s = 100 * parseInt(o / 100);
                                        if (i.citys.hasOwnProperty(s)) ; else if (!i.citys.hasOwnProperty(s)) {
                                            var a = 1e4 * parseInt(o / 1e4);
                                            i.citys.hasOwnProperty(a) || e.showModal({
                                                title: "温馨提示",
                                                content: "您选择的地址不在运营区域",
                                                showCancel: !1,
                                                confirmText: "确定",
                                                success: function(e) {
                                                    e.confirm && i.$refs.showCitys.open();
                                                }
                                            });
                                        }
                                    }
                                },
                                fail: function(t) {
                                    "getLocation:fail:ERROR_NOCELL&WIFI_LOCATIONSWITCHOFF" == t.errMsg ? (e.hideLoading(), 
                                    e.showToast({
                                        title: "请打开手机位置信息(GPS)",
                                        icon: "none"
                                    })) : e.hideLoading();
                                }
                            });
                        }
                    },
                    cussetInput: function(e) {
                        this.cussets[e.currentTarget.dataset.cusindex].info = e.detail.value;
                    },
                    showImg: function(e) {
                        this.goodsimg = e.currentTarget.dataset.img, this.showPic = !0;
                    },
                    closeShade: function() {
                        this.showPic = !1;
                    },
                    getTeck: function() {
                        "" != this.addressLngLat ? e.navigateTo({
                            url: "../getteck/getteck?lt=" + this.addressLngLat + "&iid=" + this.itemid
                        }) : e.showToast({
                            mask: !0,
                            icon: "none",
                            title: "请先选择地址"
                        });
                    },
                    showDrawer2: function() {
                        this.showGoods = !0;
                    },
                    closeDrawer2: function() {
                        this.showGoods = !1;
                    },
                    countTotoal: function() {
                        var e = 0;
                        this.goodsSelectList = [];
                        for (var t = 0; t < this.goodsList.length; t++) {
                            var i = this.accMul(Number(this.goodsList[t].marketprice), Number(this.goodsList[t].goodscount));
                            if (e += i, i > 0) {
                                var o = this.goodsList[t].id + "," + this.goodsList[t].marketprice + "," + this.goodsList[t].title + "," + this.goodsList[t].goodscount + "," + i + "|";
                                this.goodsSelectList += o;
                            }
                        }
                        this.totalprice = e.toFixed(2), this.addGoodsBtn = this.addGoods + "合计" + this.totalprice + "元";
                        var s = this.floatAdd(Number(this.payprice), Number(this.totalprice));
                        this.allprice = s.toFixed(2);
                    },
                    numberChange: function(e) {
                        this.goodsList[e[1]].goodscount = e[0], this.countTotoal();
                    },
                    floatAdd: function(e, t) {
                        var i, o, s;
                        try {
                            i = e.toString().split(".")[1].length;
                        } catch (e) {
                            i = 0;
                        }
                        try {
                            o = t.toString().split(".")[1].length;
                        } catch (e) {
                            o = 0;
                        }
                        return s = Math.pow(10, Math.max(i, o)), Number(Math.round(e * s + t * s) / s);
                    },
                    accMul: function(e, t) {
                        var i = 0, o = e.toString(), s = t.toString();
                        try {
                            i += o.split(".")[1].length;
                        } catch (e) {}
                        try {
                            i += s.split(".")[1].length;
                        } catch (e) {}
                        return Number(o.replace(".", "")) * Number(s.replace(".", "")) / Math.pow(10, i);
                    },
                    closeDialogLogin: function() {
                        this.showLogin = !1;
                    },
                    confirmLogin: function() {
                        var e = this;
                        this.closeDialogLogin();
                        var t = this.$xSign.sign("v4getopenid");
                        wx.getUserProfile({
                            desc: "为您提供更好的服务",
                            success: function(i) {
                                e.$xRequest.request({
                                    url: "entry/wxapp/v4getopenid",
                                    data: {
                                        userinfo: i.userInfo,
                                        xgsign: t,
                                        op: "userprofile"
                                    },
                                    success: function(e) {}
                                });
                            }
                        });
                    },
                    imgsChange: function(e) {
                        this.uploadImgs = "", this.uploadImg = "", this.selectedimgs = e;
                    },
                    imgLoaded: function(e) {
                        var t = new Array();
                        if (e.length > 0) {
                            for (var i = 0; i < e.length; i++) t[i] = e[i].url;
                            var o = t.join(",");
                            console.log("提交中"), this.confirmPay(o);
                        } else this.confirmPay("");
                    },
                    uploaderror: function() {
                        console.log("上传过程遇到错误");
                    },
                    textareaAInput: function(e) {
                        this.orderRemarks = e.detail.value;
                    },
                    confirmUpload: function() {
                        if (0 == this.ischeck && this.agreeContent) return e.showToast({
                            title: "请勾选左下角下单协议",
                            icon: "none"
                        }), void (this.isWxPay = !1);
                        if ("" == this.uploadImgs && this.selectedimgs.length > 0) {
                            if (0 == this.orderAddrId) return void e.showToast({
                                title: "请选择服务地址",
                                icon: "none",
                                duration: 800
                            });
                            if ((2 == this.soonVal && 1 == this.issoon || 2 == this.issoon) && ("" == this.orderTime || null == this.orderTime)) return void e.showToast({
                                title: "请选择服务时间",
                                icon: "none",
                                duration: 800
                            });
                            this.subtxt = "图片上传中", this.$refs.selectimgandupload.upload();
                        } else this.confirmPay(this.uploadImgs);
                    },
                    confirmPay: function() {
                        var t = this, i = arguments.length > 0 && void 0 !== arguments[0] ? arguments[0] : "";
                        if (0 != this.orderAddrId) if ((2 != this.soonVal || 1 != this.issoon) && 2 != this.issoon || "" != this.orderTime && null != this.orderTime) {
                            var o = "选择" + this.teckname;
                            if (1 != this.showTeck || this.tecknameBtn != o || 1 != this.selectPer) {
                                if (2 == this.issku) var s = "本次将扣除" + this.cardNum + this.cardOrder.unit + "，确认提交订单吗?"; else s = "确认提交订单吗?";
                                e.showModal({
                                    title: "温馨提示",
                                    content: s,
                                    success: function(o) {
                                        if (o.confirm) {
                                            e.showLoading({
                                                title: "提交中",
                                                mask: !0
                                            }), 2 == t.showTeck && (t.perid = 0);
                                            var s = encodeURI(JSON.stringify(t.cussets)), a = 1 == t.issku ? t.skudata.price : t.marketprice, r = t.payprice, n = t.totalprice, c = t.floatAdd(Number(t.payprice), Number(t.totalprice)), d = 1 == t.issku ? t.skudata.ids : "", u = 1 == t.issku ? t.skudata.name : "", l = 1 == t.issoon && 1 == t.soonVal ? 1 : 0;
                                            if (t.isWxPay = !0, 2 == t.issku ? t.paybtn = "提交中..." : t.paybtn = "支付中...", "wx5a67ffb91ef175cb" == t.appid || "wxcaad2fca5f5aeba1" == t.appid) var m = 1; else m = 2;
                                            var p = t.$xSign.sign("v4pay");
                                            t.$xRequest.request({
                                                url: "entry/wxapp/v4pay",
                                                data: {
                                                    xgsign: p,
                                                    oid: t.orderId,
                                                    cardid: t.cardOrderId,
                                                    payprice: r,
                                                    marketprice: a,
                                                    allprice: c,
                                                    goodsselectlist: t.goodsSelectList,
                                                    totalprice: n,
                                                    usercoupon: t.couponid,
                                                    usercoupontxt: t.couponTxt,
                                                    title: t.itemTitle,
                                                    addrid: t.orderAddrId,
                                                    addrusername: t.addressDetail.username,
                                                    addrmobile: t.addressDetail.mobile,
                                                    addrname: t.addressDetail.district,
                                                    addrdetail: t.addressDetail.province,
                                                    addraddress: t.addressDetail.address,
                                                    addrlatlng: t.addressDetail.city,
                                                    orderDate: t.orderDate,
                                                    orderTime: t.orderTime,
                                                    orderRemarks: t.orderRemarks,
                                                    itemid: t.itemid,
                                                    issku: t.issku,
                                                    skuid: d,
                                                    skuname: u,
                                                    uploadimgs: i,
                                                    perid: t.perid,
                                                    cusset: s,
                                                    soon: l,
                                                    usenum: t.cardNum,
                                                    unit: t.cardOrder.unit,
                                                    selectnum: t.selectNum,
                                                    onlyone: m,
                                                    pername: t.pername
                                                },
                                                success: function(i) {
                                                    var o = JSON.parse(t.$Decrypt(i.data.data));
                                                    if (999 == o.cardid) return t.paybtn = "已支付，跳转中", e.hideLoading(), void (t.tmplIds.length > 0 ? wx.requestSubscribeMessage({
                                                        tmplIds: t.tmplIds,
                                                        complete: function(t) {
                                                            setTimeout(function() {
                                                                e.reLaunch({
                                                                    url: "/xg_o2o/order/order"
                                                                });
                                                            }, 800);
                                                        }
                                                    }) : setTimeout(function() {
                                                        e.reLaunch({
                                                            url: "/xg_o2o/order/order"
                                                        });
                                                    }, 800));
                                                    i.data && o && !i.data.errno && wx.requestPayment({
                                                        timeStamp: o.timeStamp,
                                                        nonceStr: o.nonceStr,
                                                        package: o.package,
                                                        signType: "MD5",
                                                        paySign: o.paySign,
                                                        success: function(i) {
                                                            t.paybtn = "已支付，跳转中", e.hideLoading(), e.showToast({
                                                                title: "支付成功",
                                                                icon: "none",
                                                                duration: 800
                                                            }), t.tmplIds.length > 0 ? wx.requestSubscribeMessage({
                                                                tmplIds: t.tmplIds,
                                                                complete: function(t) {
                                                                    setTimeout(function() {
                                                                        e.reLaunch({
                                                                            url: "/xg_o2o/order/order"
                                                                        });
                                                                    }, 800);
                                                                }
                                                            }) : setTimeout(function() {
                                                                e.reLaunch({
                                                                    url: "/xg_o2o/order/order"
                                                                });
                                                            }, 800);
                                                        },
                                                        fail: function(i) {
                                                            t.isWxPay = !1, t.paybtn = "微信支付", e.hideLoading(), "requestPayment:fail cancel" == i.errMsg && (e.showToast({
                                                                title: "支付取消",
                                                                icon: "none",
                                                                duration: 800
                                                            }), setTimeout(function() {
                                                                e.redirectTo({
                                                                    url: "/xg_o2o/order/order"
                                                                });
                                                            }, 800));
                                                        }
                                                    });
                                                },
                                                fail: function(i) {
                                                    t.isWxPay = !1, e.hideLoading(), 2 == t.issku ? t.paybtn = "提交订单" : t.paybtn = "微信支付", 
                                                    wx.showModal({
                                                        title: "系统提示",
                                                        content: i.data.message ? i.data.message : "错误",
                                                        showCancel: !1,
                                                        success: function(e) {
                                                            e.confirm;
                                                        }
                                                    });
                                                }
                                            });
                                        }
                                    }
                                });
                            } else e.showToast({
                                title: "请选择" + this.teckname,
                                icon: "none",
                                duration: 800
                            });
                        } else e.showToast({
                            title: "请选择服务时间",
                            icon: "none",
                            duration: 800
                        }); else e.showToast({
                            title: "请选择服务地址",
                            icon: "none",
                            duration: 800
                        });
                    }
                }
            };
            t.default = a;
        }).call(this, i("543d").default);
    },
    "9b35": function(e, t, i) {},
    bb21: function(e, t, i) {
        "use strict";
        i.d(t, "b", function() {
            return s;
        }), i.d(t, "c", function() {
            return a;
        }), i.d(t, "a", function() {
            return o;
        });
        var o = {
            gracePage: function() {
                return i.e("graceUI/components/gracePage").then(i.bind(null, "1915"));
            },
            graceFullLoading: function() {
                return i.e("graceUI/components/graceFullLoading").then(i.bind(null, "7669"));
            },
            graceDialog: function() {
                return i.e("graceUI/components/graceDialog").then(i.bind(null, "8d15"));
            },
            divider: function() {
                return i.e("components/divider/divider").then(i.bind(null, "bdb7"));
            },
            graceNumberBox: function() {
                return i.e("graceUI/components/graceNumberBox").then(i.bind(null, "6774"));
            },
            graceSelectTags: function() {
                return i.e("graceUI/components/graceSelectTags").then(i.bind(null, "1e05"));
            },
            graceSelectImgAndUpload: function() {
                return Promise.all([ i.e("common/vendor"), i.e("graceUI/components/graceSelectImgAndUpload") ]).then(i.bind(null, "d7ef"));
            },
            graceDrawer: function() {
                return i.e("graceUI/components/graceDrawer").then(i.bind(null, "8ea9"));
            },
            graceShade: function() {
                return i.e("graceUI/components/graceShade").then(i.bind(null, "6b7b"));
            },
            graceCheckBtn: function() {
                return i.e("graceUI/components/graceCheckBtn").then(i.bind(null, "d274"));
            }
        }, s = function() {
            this.$createElement, this._self._c;
        }, a = [];
    },
    ccf0: function(e, t, i) {
        "use strict";
        (function(e) {
            function t(e) {
                return e && e.__esModule ? e : {
                    default: e
                };
            }
            i("4e1e"), t(i("66fd")), e(t(i("eecf")).default);
        }).call(this, i("543d").createPage);
    },
    daa6: function(e, t, i) {
        "use strict";
        var o = i("9b35");
        i.n(o).a;
    },
    e69c: function(e, t, i) {
        "use strict";
        i.r(t);
        var o = i("67a0"), s = i.n(o);
        for (var a in o) "default" !== a && function(e) {
            i.d(t, e, function() {
                return o[e];
            });
        }(a);
        t.default = s.a;
    },
    eecf: function(e, t, i) {
        "use strict";
        i.r(t);
        var o = i("bb21"), s = i("e69c");
        for (var a in s) "default" !== a && function(e) {
            i.d(t, e, function() {
                return s[e];
            });
        }(a);
        i("daa6");
        var r = i("f0c5"), n = Object(r.a)(s.default, o.b, o.c, !1, null, null, null, !1, o.a, void 0);
        t.default = n.exports;
    }
}, [ [ "ccf0", "common/runtime", "common/vendor" ] ] ]);